import PROMPTS_TEMPLATE from '../template/json/prompts-en.json';


export const EnMsg = {
    MIXLY_LIB_ARDUINO_LLM_INIT: 'Initialize',
    MIXLY_LIB_ARDUINO_LLM_CHATBOT: 'Chatbot',
    MIXLY_LIB_ARDUINO_LLM_API_KEY: 'API key',
    MIXLY_LIB_ARDUINO_LLM_MODEL: 'Model',
    MIXLY_LIB_ARDUINO_LLM_SYSTEM_PROMPT: 'System prompt',
    MIXLY_LIB_ARDUINO_LLM_SET_API_KEY: 'set API key',
    MIXLY_LIB_ARDUINO_LLM_SET_TIMEOUT: 'set request timeout',
    MIXLY_LIB_ARDUINO_LLM_SET_MAX_RETRIES: 'set maximum number of retries',
    MIXLY_LIB_ARDUINO_LLM_SET_SYSTEM_PROMPT: 'set system prompt',
    MIXLY_LIB_ARDUINO_LLM_SELECT_MODEL: 'select model',
    MIXLY_LIB_ARDUINO_LLM_MODEL_PROVIDER: 'Model provider',
    MIXLY_LIB_ARDUINO_LLM_MODEL_NAME: 'Model name',
    MIXLY_LIB_ARDUINO_LLM_ENABLE_HISTORY_MESSAGES: 'enable history',
    MIXLY_LIB_ARDUINO_LLM_SET_HISTORY_MESSAGES_NUM: 'set the number of history',
    MIXLY_LIB_ARDUINO_LLM_CHAT: 'chat',
    MIXLY_LIB_ARDUINO_LLM_USER_PROMPT: 'User prompt',
    MIXLY_LIB_ARDUINO_LLM_MAX_TOKENS: 'Max tokens',
    MIXLY_LIB_ARDUINO_LLM_CHAT_STREAM: 'chat (stream)',
    MIXLY_LIB_ARDUINO_LLM_CONTENT_CALLBACK: 'Content callback',
    MIXLY_LIB_ARDUINO_LLM_REASONING_CONTENT_CALLBACK: 'Reasoning content callback',
    MIXLY_LIB_ARDUINO_LLM_PROMPTS_TEMPLATE: [],
    MIXLY_LIB_ARDUINO_LLM_PROVIDERS: [
        ['DeepSeek', 'DeepSeek'],
        ['ChatGPT', 'ChatGPT'],
        ['AliyunBaiLian', 'AliyunBaiLian'],
        ['BaiChuanAI', 'BaiChuanAI'],
        ['LingYiWanWu', 'LingYiWanWu'],
        ['MoonShot', 'MoonShot'],
        ['SiliconFlow', 'SiliconFlow'],
        ['TencentHunYuan', 'TencentHunYuan'],
        ['VolcEngine', 'VolcEngine'],
        ['Custom', 'Custom']
    ],
    MIXLY_LIB_ARDUINO_LLM_PROMPTS_TEMPLATE_MAP: {},
};

for (let item of PROMPTS_TEMPLATE) {
    const name = item['act'].replace(/[^a-zA-Z0-9_]/g, "_");
    EnMsg.MIXLY_LIB_ARDUINO_LLM_PROMPTS_TEMPLATE.push([item['act'], name]);
    EnMsg.MIXLY_LIB_ARDUINO_LLM_PROMPTS_TEMPLATE_MAP[name] = {
        name: name.toUpperCase(),
        prompt: item['prompt']
    };
}

export const EnCatgories = {
    'mixly-lib-arduino-llm': 'AIChatbot'
};